<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>伪元素</title>
</head>
<body>
<p>首行</p>
<p>来呀，伤害呀 <br/>不要来</p>
<p>再来呀</p>
<p>first-letter ;设置首字母</p>
<p class="p1">伪元素与css类结合</p>
<p class="p2">before伪元素</p>
<p class="p3">after伪元素</p>
</body>
<style>
    p:first-line{
        background-color: green;
    }
    p:first-letter{
        background-color: red;
    }
    p.p1:first-letter{
        font-size:200px
    }
    p.p2:before{
        content: url("../img/a.gif ");
    }
    p {
        font-size: 100px;
    }
    p.p3:after{
        content: url("../img/b.gif");
    }

</style>
</html>
